Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[config reload] Removed replace irreversibly job-mode for sonic.target restart #1820

Merged
merged 1 commit into from
Sep 15, 2021

Conversation

vivekrnv
Copy link
Contributor

@vivekrnv vivekrnv commented Sep 14, 2021

Signed-off-by: Vivek Reddy Karri [email protected]

What I did

As discussed in this PR #1814 (comment), only the stop.job should have job-mode set to replace irreversibly.

Otherwise, simultaneous config reloads in the quick succession, can lead to the behavior.

Although ,when the restart job (and all the other dependent jobs) are finished and is taken out of systemd's job queue, the next stop job will not be cancelled.

admin@sonic:~$ sudo systemctl restart sonic.target --job-mode replace-irreversibly
admin@sonic:~$ sudo systemctl stop sonic.target --job-mode replace-irreversibly (Ran Immediately)
Failed to stop sonic.target: Transaction for sonic.target/stop is destructive (ntp-config.service has 'start' job queued, but 'stop' is included in transaction).
See system logs and 'systemctl status sonic.target' for details.
(After all the dependent jobs of restart sonic.target  are done, it works)
admin@sonic:~$ sudo systemctl stop sonic.target --job-mode replace-irreversibly
admin@sonic:

How I did it

How to verify it

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

@vivekrnv
Copy link
Contributor Author

@stepanblyschak , @nazariig, @rajendra-dendukuri, @qiluo-msft Please review

@vivekrnv
Copy link
Contributor Author

Required for 202012

@nazariig
Copy link
Collaborator

@qiluo-msft
Copy link
Contributor

qiluo-msft commented Sep 15, 2021

Do you need it on 202106 branch?

@vivekrnv
Copy link
Contributor Author

Do you need it on 20202106 branch?

Yes

@qiluo-msft qiluo-msft merged commit ce11545 into sonic-net:master Sep 15, 2021
qiluo-msft pushed a commit that referenced this pull request Sep 15, 2021
#### What I did

As discussed in this PR #1814 (comment), only the stop.job should have job-mode set to replace irreversibly.

Otherwise,  simultaneous config reloads in the quick succession, can lead to the behavior.

Although ,when the restart job (and all the other dependent jobs) are finished and is taken out of systemd's job queue, the next stop job will not be cancelled.
judyjoseph pushed a commit that referenced this pull request Sep 27, 2021
#### What I did

As discussed in this PR #1814 (comment), only the stop.job should have job-mode set to replace irreversibly.

Otherwise,  simultaneous config reloads in the quick succession, can lead to the behavior.

Although ,when the restart job (and all the other dependent jobs) are finished and is taken out of systemd's job queue, the next stop job will not be cancelled.
stepanblyschak pushed a commit to stepanblyschak/sonic-utilities that referenced this pull request Apr 18, 2022
Included Commits
92d0744 [config reload] Removed job-mode for sonic.target restart (sonic-net#1820)
c28fb22 [ci]: Support PR coverage (sonic-net#1806)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants